package com.course.chapter7;

import java.util.Random;
import java.util.concurrent.TimeUnit;

public class RunnableDemo implements Runnable{
    @Override
    public void run() {
        try {
            TimeUnit.SECONDS.sleep(new Random().nextInt(10));
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        System.out.println(Thread.currentThread()+"开始运行了");
    }
}
